package ch.ethz.fcl.user.interaction;

import ch.ethz.fcl.draw.Circle;
import android.util.Log;
import android.view.MotionEvent;
import android.view.View;
import android.view.View.OnTouchListener;

public class TouchScreen implements OnTouchListener{
	private Circle circle;
	private final String TAG = "TouchScreen";
	
	public TouchScreen(Circle circle){
		this.circle = circle;
	}
	@Override
	public boolean onTouch(View v, MotionEvent event) {
		circle.x = event.getX() + 45;
		circle.y = event.getY();
		circle.invalidate();
		String posInfo = "X: "+event.getX()+" Y: "+event.getY();
		Log.d(TAG, posInfo);
		return true;
	}
}